<%#
kind: PXEGrub2
name: Preseed default PXEGrub2 Autoinstall
model: ProvisioningTemplate
oses:
- Ubuntu
test_on:
- ubuntu_autoinst4dhcp
%>
#
# This file was deployed via '<%= template_name %>' template
#
# Supported host/hostgroup parameters:
#
# blacklist = module1, module2
#   Blacklisted kernel modules
#
# lang = en_US
#   System locale
#
<%
  os_major = @host.operatingsystem.major.to_i

  if (os_major > 12 && os_major < 24)
    efi_suffix = 'efi'
  else
    efi_suffix = ''
  end
-%>

set default=0
set timeout=<%= host_param('loader_timeout') || 10 %>

menuentry '<%= template_name %>' {
  linux<%= efi_suffix %> <%= @kernel %> root=/dev/rd/0 rw auto <%= snippet('preseed_kernel_options_autoinstall', variables: {add_userdata_quotes: true}).strip %>
  initrd<%= efi_suffix %> <%= @initrd %>
}

<%= snippet_if_exists(template_name + " custom menu") %>

